import Vuex from '@wepy/x';

export default new Vuex.Store({
  state: {
    vrUrl: '',
    counter: 0,
    vrUrl: '',
    videoUrl: '',
    searchHidden: false,
    premiseImgList: [],
    modelImgList: [],
    selectModelImgList: [],
    premiseSellDetail: '',
    customerDetail: {}
  },
  getters: {
    vrUrl: (state) => state.vrUrl,
    videoUrl: (state) => state.videoUrl,
    searchHidden: (state) => state.searchHidden,
    premiseImgList: (state) => state.premiseImgList,
    modelImgList: (state) => state.modelImgList,
    selectModelImgList: (state) => state.selectModelImgList,
    premiseSellDetail: (state) => state.premiseSellDetail,
    customerDetail: (state) => state.customerDetail,
  },
  mutations: {
    setVRurl (state, data) {
      state.vrUrl = data
    },
    setVideoUrl (state, data) {
      state.videoUrl = data
    },
    setHidden (state, data) {
      state.searchHidden = data
    },
    setPremiseImgList (state, data) {
      state.premiseImgList = data
    },
    setModelImgList (state, data) {
      state.modelImgList = data
    },
    setSelectModelImgList (state, data) {
      state.selectModelImgList = data
    },
    setPremiseSellDetail (state, data) {
      state.premiseSellDetail = data
    },
    setCustomerDetail (state, data) {
      state.customerDetail = data
    },
  },
  actions: {

  }
});
